#include "word.h"
#include "tag.h"
using namespace std;

Word::Word(string s,int tag) :Token(tag),lexeme(s) {}

string Word::toString(void) const {
	return "<"+lexeme+">";
}

string Word::getLexeme(void) const {
	return lexeme;
}

Word* Word::clone(void) const {
	return new Word(*this);
}

const Word Word::AND("&&",Tag::AND),
Word::OR("||",Tag::OR),
Word::EQ("==",Tag::EQ),
Word::NE("!=",Tag::NE),
Word::LE("<=",Tag::LE),
Word::GE(">=",Tag::GE),
Word::MINUS("minus",Tag::MINUS),
Word::TRUE("true",Tag::TRUE),
Word::FALSE("false",Tag::FALSE),
Word::TEMP("t",Tag::TEMP);